<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<style>
		
		#log{
			
			width:150px;
			height: 150px;
		}
		#log2{
			display: none;
		}
	</style>
	<body>
		<div id="box">
			<img id="log"  src="img/小二维码.jpg" />
			<img id="log2" src="img/二维码1.jpeg"/>
			<button id="btn">显示二维码1</button>
			
		</div>
		
	</body>
	<script>
		window.onload = function(){
		var log = document.getElementById("log")
		var log2 = document.getElementById("log2")
		var btn = document.getElementById("btn")
				
			log.onmousedown = function()
			{ log2.style.display = "block";}
			
		
			log2.onmouseover = function()
			{ log2.src = "img/二维码2.jpg";}
			if(btn.innerText === "显示二维码1"){
				btn.onclick = function(){
					log2.style.display = "block";
					log2.src = "img/二维码1.jpg";
					btn.innerText = "点击大二维码";
				}
			}
			else{
				btn.innerText = "没啊";
					
			}
		}
		
	</script>
</html>
